import type { Response } from '@/api/config/types';
import axios from 'axios';

const prefix = `/ax/userAssets`;

export const getUserTheme = () => {
  return axios.get<Response<{ data: string }>>(`${prefix}/theme`);
};
/* 保存用户的主题信息，如果存在则覆盖 */
export const uploadUserTheme = (data: string) => {
  return axios.post<Response>(`${prefix}/theme`, {
    data,
  });
};
